﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Collections.ObjectModel;

namespace Prueba.Model
{
    public class PosColInfo : ModelBase
    {
        public ObservableCollection<PosColInfo> PosCols
        {
            get { return _PosCols; }
            set
            {
                if (_PosCols != value)
                {
                    _PosCols = value;
                    OnPropertyChanged(PosColsPropertyName);
                }
            }
        }
        private ObservableCollection<PosColInfo> _PosCols;
        public const string PosColsPropertyName = "PosCols";

        public string PosColTitle
        {
            get { return _PosColTitle; }
            set
            {
                if (_PosColTitle != value)
                {
                    _PosColTitle = value;
                    OnPropertyChanged(PosColTitlePropertyName);
                }
            }
        }
        private string _PosColTitle;
        public const string PosColTitlePropertyName = "PosColTitle";

        public bool IsVisible
        {
            get { return _IsVisible; }
            set
            {
                if (_IsVisible != value && this._PosColTitle.ToLower()!="pos")
                {
                    _IsVisible = value;
                    OnPropertyChanged(IsVisiblePropertyName);
                }
            }
        }
        private bool _IsVisible;
        public const string IsVisiblePropertyName = "IsVisible";

        public PosColInfo(string PosColTitle, bool IsVisible, ObservableCollection<PosColInfo> PosCols)
        {
            this._PosColTitle = PosColTitle;
            this._IsVisible = IsVisible;
            this._PosCols = PosCols;
        }
    }
}
